package com.letoken.platform.job.constant;

import java.util.Arrays;
import java.util.List;

/**
 * SerumVial webScoket相关常量类
 *
 * @version 1.0
 * @author： letokenlabs
 * @date： 2021/7/1 16:06
 */
public class SerumVialConstant {

    public static final String SERUMVIAL_TYPE = "type";
    public static final String SERUMVIAL_TRADES = "trades";
//    public static final String SERUMVIAL_WSURL = "ws://serum-vial/v1/ws";
    public static final String SERUMVIAL_WSURL = "wss://serum-vial.letoken.finance/v1/ws";
//    public static final String SERUMVIAL_WSURL = "ws://47.115.31.125:8000/v1/ws";
//    public static final String SERUMVIAL_WSURL = "ws://127.0.0.1:8000/v1/ws";

    //项目初始化的拉取链上配置信息 value 0：关闭 1：开启
    public static final String INIT_TYPE_APP_LETOKEN = "INIT_TYPE_APP_LETOKEN";

    /**
     * ws重新连接等待时间：1000毫秒 = 1秒
     */
    public static final Integer ONCE_CONNECTION_WAIT_TIME = 1000;

    /**
     * ws重新连接最大等待时间，超过则跳出：1000毫秒 * 60 = 1分钟
     */
    public static final Integer MAX_CONNECTION_WAIT_TIME = 1000 * 60;

    /**
     * 系统所支持的所有颗粒度
     */
    public static List<String> ALL_RESOLUTION = Arrays.asList(
            "1min",
            "5min",
            "15min",
            "30min",
            "1hour",
            "4hour",
            "1day",
            "1week",
            "1mon"
            );

}
